GraphicsFormats package for Buoy

RawIcoExporter.SaveToBytes Method

Saves a single bitmap to ICO formatted Bytes buffer.

SaveToBytes(
   image as RawBitmap) as Bytes

Parameters

image
The bitmap to be saved into ICO file. This must be RGB color space, and 8 bit per channel bitmap.

Returns

Bytes
ICO formatted Bytes buffer or nil if there was error.

Remarks

Note this method will clear images that have been added with AddBitmap.

This method is basically macro for:
Clear added bitmaps
AddBitmap (one bitmap)
SaveBitmapsToBytes


This method can throw GraphicsFormatsException.

See Also

RawIcoExporter Class